
package org.sunspotworld.demo;

public class RestMatrix extends DecisionMatrix
{
    private static final int size = 2;
    
    public RestMatrix()
    {
        super(size);
        initializeRoleMatrix();
        intializeAVMatrices();
    }

    private void intializeAVMatrices()
    {
        
        m_lowestValence = new float[][]{{1, 1},
                                        {1, 1}};

        m_highestValence = new float[][]{{1, 1},
                                        {1, 1}};

        m_lowestArousal = new float[][]{{9, 2},
                                         {10, 2}};

        m_highestArousal = new float[][]{{5, 1},
                                         {50, 1}};
    }
    
    private void initializeRoleMatrix()
    {
        if(SunSpotAudio.m_role == SunSpotAudio.role_harmony)
        {
            m_roleMatrix[0][0] = 5;
            m_roleMatrix[0][1] = 1;
            m_roleMatrix[1][0] = 20;
            m_roleMatrix[1][1] = 1;
        }
        else if(SunSpotAudio.m_role == SunSpotAudio.role_bass)
        {
            m_roleMatrix[0][0] = 10;
            m_roleMatrix[0][1] = 1;
            m_roleMatrix[1][0] = 20;
            m_roleMatrix[1][1] = 1;
        }
        else if(SunSpotAudio.m_role == SunSpotAudio.role_percussion)
        {
            m_roleMatrix[0][0] = 20;
            m_roleMatrix[0][1] = 1;
            m_roleMatrix[1][0] = 20;
            m_roleMatrix[1][1] = 1;   
        }
        else //if(SunSpotAudio.m_role == SunSpotAudio.role_melody)
        {
            m_roleMatrix[0][0] = 4;
            m_roleMatrix[0][1] = 1;
            m_roleMatrix[1][0] = 20;
            m_roleMatrix[1][1] = 1;
        }
    }
    
    public void weightByAV(AV av)
    {
        
        fixAllRows();
    }
}
